// tsx 中模拟 v-bind 语法
import { reactive } from "vue";

interface List {
  name: string;
  age: number;
}

let list = reactive<List[]>([
  {
    name: "张三",
    age: 10,
  },
  {
    name: "李四",
    age: 18,
  },
]);

const tsxDom = () => {
  return (
    <>
      {list.map((item) => {
        return <div data-name={item.name}>{item.age}</div>;
      })}
    </>
  );
};

export default tsxDom;
